/*
 * Copyright 2020-2030 the original author or authors.
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *      https://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
*/

package com.gitee.minimalismstyle.fresh.sys.api.model

import com.fasterxml.jackson.annotation.JsonFormat
import com.fasterxml.jackson.annotation.JsonIgnore
import com.gitee.minimalismstyle.fresh.common.data.beetl.model.LongModel
import io.swagger.annotations.*
import java.time.LocalDate


/**
 * 用户Model
 * @author maochao
*/
@ApiModel(value = "用户")
open class SysUser: LongModel(){

    /**
    * 用户名
    */
    @ApiModelProperty(value = "用户名")
    var username: String? = null

    /**
    * 密码
    */
    @ApiModelProperty(value = "密码")
    @JsonIgnore
    var password: String? = null

    /**
    * 昵称
    */
    @ApiModelProperty(value = "昵称")
    var petname: String? = null

    /**
    * 真实姓名
    */
    @ApiModelProperty(value = "真实姓名")
    var realname: String? = null

    /**
    * 头像
    */
    @ApiModelProperty(value = "头像")
    var avatar: String? = null

    /**
    * 性别
    */
    @ApiModelProperty(value = "性别")
    var gender: String? = null

    /**
    * 生日
    */
    @ApiModelProperty(value = "生日")
    @JsonFormat(locale="zh", timezone="GMT+8", pattern="yyyy-MM-dd")
    var birthday: LocalDate? = null

    /**
    * 电话
    */
    @ApiModelProperty(value = "电话")
    var phone: String? = null

    /**
    * 邮箱
    */
    @ApiModelProperty(value = "邮箱")
    var email: String? = null

    /**
    * 国家
    */
    @ApiModelProperty(value = "国家")
    var country: String? = null

    /**
    * 默认组别ID
    */
    @ApiModelProperty(value = "默认组别ID")
    var groupId: Long? = null

    /**
    * 默认角色ID
    */
    @ApiModelProperty(value = "默认角色ID")
    var roleId: Long? = null

    /**
    * 备用字段1
    */
    @ApiModelProperty(value = "备用字段1")
    var attr1: String? = null

    /**
    * 备用字段2
    */
    @ApiModelProperty(value = "备用字段2")
    var attr2: String? = null

    /**
    * 备用字段3
    */
    @ApiModelProperty(value = "备用字段3")
    var attr3: String? = null

    /**
    * 备用字段4
    */
    @ApiModelProperty(value = "备用字段4")
    var attr4: String? = null

    /**
    * 备用字段5
    */
    @ApiModelProperty(value = "备用字段5")
    var attr5: String? = null
}